import request from '../api/request.js';
	const mixin = {
		checkUserLogin: async function() {
			let token = uni.getStorageSync('token');
			if (!token) {
				
				uni.showModal({
					title: '你还没有登陆',
					success: function(e) {
						// console.log(e);
						if (e.confirm) {
							uni.navigateTo({
								url: '/pages/login/login'
							})
						} else if (e.cancel) {
							uni.showToast({
								title: '你取消了'
							})
						}
					}
				})
				return false
			} else {
				return true
			}

		}
	}

	export default mixin;
